package com.liming.common.pojo.dto.product;


import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.liming.common.pojo.dto.PageDTO;
import com.liming.common.serializer.YuanToCentDeserializer;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;


/**
 * @author liming
 * @date 2025/1/17
 */
@Data
@Schema(description = "商品查询条件")
@EqualsAndHashCode(callSuper = true)
public class ProductPageQuery extends PageDTO {

    @Schema(description = "商品名称")
    private String name;

    @Schema(description = "商品型号")
    private String modelNumber;

    @Schema(description = "商品售价下限")
    @JsonDeserialize(using = YuanToCentDeserializer.class)
    private Integer lowPrice;

    @Schema(description = "商品售价上限")
    @JsonDeserialize(using = YuanToCentDeserializer.class)
    private Integer highPrice;

    @Schema(description = "品牌ID")
    private Long brandId;

    @Schema(description = "分类ID")
    private Long categoryId;

    @Schema(description = "商品上架情况（0：下架，1：上架）")
    private Integer onShelf;
}
